import { ModalDefaultProps } from './props';
Component({
    props: ModalDefaultProps,
    methods: {
        onClose: function () {
            var onClose = this.props.onClose;
            if (onClose) {
                onClose();
            }
        },
        onMaskClose: function () {
            var _a = this.props, onClose = _a.onClose, maskClosable = _a.maskClosable;
            if (maskClosable && onClose) {
                onClose();
            }
        },
        onPrimaryButtonTap: function () {
            var onPrimaryButtonTap = this.props.onPrimaryButtonTap;
            if (onPrimaryButtonTap) {
                onPrimaryButtonTap();
            }
        },
        onSecondaryButtonTap: function () {
            var onSecondaryButtonTap = this.props.onSecondaryButtonTap;
            if (onSecondaryButtonTap) {
                onSecondaryButtonTap();
            }
        },
        onCancelButtonTap: function () {
            var onCancelButtonTap = this.props.onCancelButtonTap;
            if (onCancelButtonTap) {
                onCancelButtonTap();
            }
        },
    },
});
